package org.yanghe.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;
import org.yanghe.service.OpenFeginService;

import javax.annotation.Resource;

@RestController
public class OpenFeginController {

    @Resource
    private OpenFeginService service;

    @GetMapping("/consumer/openfegin/{name}")
    public String openFegin(@PathVariable("name") String name){
        return service.hello(name)+"| OpenFegin";
    }

    @GetMapping("/consumer/timeout/{name}")
    public String testTimeOut(@PathVariable("name") String name){
        return service.testTimeOut(name)+"| OpenFegin";
    }
}
